package main;

import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Test {
    public static void main(String[] args) {
        String string = "http://mooctest-site-dev.oss-cn-shanghai.aliyuncs.com/bababababababab.adadasda/";
        int index = string.indexOf("aliyuncs.com");
        Matcher m = Pattern.compile("http://([^\"]*)aliyuncs.com").matcher(string);
        if (m.find())
            System.out.println(m.group());
    }
}
